package com.woniu.web.mapper;

import com.woniu.common.entity.TbJpPermission;
import com.woniu.common.entity.TbJpPermissionExample;
import java.util.List;

import com.woniu.shiro.pojo.RoleTree;
import com.woniu.shiro.pojo.Trees;
import org.apache.ibatis.annotations.Param;

public interface TbJpPermissionDao {
    long countByExample(TbJpPermissionExample example);

    int deleteByExample(TbJpPermissionExample example);

    int deleteByPrimaryKey(Integer permissionId);

    int insert(TbJpPermission record);

    int insertSelective(TbJpPermission record);

    List<TbJpPermission> selectByExample(TbJpPermissionExample example);

    TbJpPermission selectByPrimaryKey(Integer permissionId);

    int updateByExampleSelective(@Param("record") TbJpPermission record, @Param("example") TbJpPermissionExample example);

    int updateByExample(@Param("record") TbJpPermission record, @Param("example") TbJpPermissionExample example);

    int updateByPrimaryKeySelective(TbJpPermission record);

    int updateByPrimaryKey(TbJpPermission record);

    List<RoleTree> findAllPermissionTree();
    List<Trees> UserIdToCheckPermissionByUserId(@Param("userId") Integer userId,@Param("parentId") Integer parentId);
    List<Trees> UserIdToCheckPermissionByPhone(Long phone);
}